package Search.Order;

public class OrderSearch {
    public static void main(String[] args) {
        int []arr=new int[]{23,34,56,78,12,5,68,9,7,54};
        boolean flag=true;
        for (int i = 0; i < arr.length; i++) {
            if (arr[i] == 5) {
                flag = false;
                System.out.println("找到了，索引为" + i);
                break;
            }
        }
        if(flag)
            System.out.println("没找到");
    }
}
